package com.css.order.exception;

import com.css.order.enums.ResultEnum;
import lombok.Getter;

/**
 * <p>
 * -
 * </p>
 *
 * @author css
 * @since 2019/12/27
 */
public class OrderException extends RuntimeException {
    @Getter
    private Integer code;

    public OrderException(ResultEnum message) {
        super(message.getMessage());
        this.code = message.getCode();
    }

    public OrderException(Integer code, String message) {
        super(message);
        this.code = code;
    }
}
